Copyright: Copyright © 2001 Alexander Minza


About

FNGraph 2.51
Graphing and analyzing mathematical functions

alex_minza@hotmail.com

http://www.ournet.md/~fngraph


Expressions

	a*b
	a/b
	a^b
	sqr(a)
	b^(1/a)
	abs(a)
	log(a,b)
	sin(a)^2
	sin(a^2)


Syntax of Expressions

Variable	Description
x	Function argument
Constant	Value
e	2.71828182845905
pi	3.14159265358979
Operator	Name
+	Addition
-	Subtraction, Negation
*	Multiplication
/	Division
^	Exponentiation
!	Factorial
Function	Name	Aliases
abs	Absolute Value
arccos	Inverse Cosine	acos
arccosec	Inverse Cosecant	acsc, arccsc
arccotan	Inverse Cotangent	acot, arccot
arcsec	Inverse Secant	asec
arcsin	Inverse Sine	asin
atn	Inverse Tangent	arctan, arctg, atan
cos	Cosine
cosec	Cosecant	csc
cotan	Cotangent	ctg, cot
exp	Exponential
fix	Integer Portion	trunc
harccos	Inverse Hyperbolic Cosine	acosh, arccosh
harccosec	Inverse Hyperbolic Cosecant	acsch, arccsch
harccotan	Inverse Hyperbolic Cotangent	acoth, arccoth
harcsec	Inverse Hyperbolic Secant	asech, arcsech
harcsin	Inverse Hyperbolic Sine	asinh, arcsinh
harctan	Inverse Hyperbolic Tangent	atanh, arctanh
hcos	Hyperbolic Cosine	cosh, ch
hcosec	Hyperbolic Cosecant	csch
hcotan	Hyperbolic Cotangent	coth, cth
hsec	Hyperbolic Secant	sech
hsin	Hyperbolic Sine	sinh, sh
htan	Hyperbolic Tangent	tanh, th
int	Integer Portion
lg	Logarithm base 10
ln	Natural Logarithm
log	Logarithm
max	Maximum
min	Minimum
mod	Modulo
sec	Secant
sgn	Sign	sign
sin	Sine
sqr	Square Root	sqrt
tan	Tangent	tg


Examples of Expressions

Parabola

x^2

Hyperbola

1/x

Semicubical parabola

(x^2)^(1/3)

McLaurin polynomial

x-x^3/3!+x^5/5!-x^7/7!

Functions

sin(x)

sin(exp(x))

Two argument functions

min(0,sin(x))

log(2,x)

Miscellaneous

sin(0.6*x+0.3)/(1.7+cos(x*x+1.2))

exp(1+sin(atan(x))^2)-x


Operator Precedence

When several operations occur in an expression, each part is evaluated and resolved in a predetermined order called operator precedence. Parentheses can be used to override the order of precedence and force some parts of an expression to be evaluated before other parts. Operations within parentheses are always performed before those outside. Within parentheses, however, normal operator precedence is maintained.

Arithmetic operators are evaluated in the following order of precedence:

!		Factorial
^		Exponentiation
-		Negation
*	/	Multiplication and Division
+	-	Addition and Subtraction

When multiplication and division occur together in an expression, each operation is evaluated as it occurs from left to right. Likewise, when addition and subtraction occur together in an expression, each operation is evaluated in order of appearance from left to right.

You can enclose any operand in parentheses. For example, in the expression: (10+5)/5 the parentheses around 10+5 mean that the value of 10+5 is evaluated first and it becomes the left operand of the division (/) operator. The result of (10+5)/5 is 3. Without the parentheses, 10+5/5 would evaluate to 11.


Numerical issues

Because the expressions are evaluated using double precision floating point numbers, roundoff errors will inevitably affect calculations. This is especially true when the function's argument takes extreme values.

Example:

Since the value of pi on a computer can only be an approximation of pi, tan(pi/2) is not undefined, but returns a very large number.


Keyboard shortcuts

Key	Function
Cursor keys	Move
+	Zoom In
-	Zoom Out
/	Zoom Min
*	Zoom Max
Insert	Center Axes
Enter	Zoom Default